package com.ruiysoft.controller.order.vo;

import com.fasterxml.jackson.annotation.JsonProperty;
import io.swagger.annotations.ApiModelProperty;
import org.springframework.validation.annotation.Validated;

import java.math.BigDecimal;
import java.util.Objects;

/**
 * OrderSkuListCusVo
 */
@Validated
@javax.annotation.Generated(value = "io.swagger.codegen.languages.SpringCodegen", date = "2018-10-27T20:58:54.914+08:00")

public class OrderSkuListCusVo {
    @JsonProperty("spuId")
    private Long spuId = null;

    @JsonProperty("skuId")
    private Long skuId = null;

    @JsonProperty("skuName")
    private String skuName = null;

    @JsonProperty("quantity")
    private Integer quantity = null;

    @JsonProperty("unitPrice")
    private BigDecimal unitPrice = null;

    /**
     * 价格策略：包括是否会员价，是否虚拟货币等等
     */
    @JsonProperty("priceStrategy")
    private Integer priceStrategy;
    /**
     * 固定虚拟币总额（至少需要支付的虚拟币：针对现金+固定虚拟币的商品）
     */
    @JsonProperty("virtualCoinPrice")
    private Long virtualCoinPrice = null;

    /**
     * 经过计算后的商品总额
     */
    @JsonProperty("totalAmount")
    private BigDecimal totalAmount;

    /**
     * 经过计算后的总现金
     */
    @JsonProperty("totalCash")
    private BigDecimal totalCash;
    /**
     * 经过计算后的虚拟币支付总额。根据会员的现有积分，进行积分最大化支付计算后的数值，并非从数据库查询出来的。
     */
    @JsonProperty("virtualCoin")
    private Long virtualCoin = null;


    public Integer getPriceStrategy() {
        return priceStrategy;
    }

    public void setPriceStrategy(Integer priceStrategy) {
        this.priceStrategy = priceStrategy;
    }

    public Long getVirtualCoinPrice() {
        return virtualCoinPrice;
    }

    public void setVirtualCoinPrice(Long virtualCoinPrice) {
        this.virtualCoinPrice = virtualCoinPrice;
    }

    public BigDecimal getTotalAmount() {
        return totalAmount;
    }

    public void setTotalAmount(BigDecimal totalAmount) {
        this.totalAmount = totalAmount;
    }

    public BigDecimal getTotalCash() {
        return totalCash;
    }

    public void setTotalCash(BigDecimal totalCash) {
        this.totalCash = totalCash;
    }

    public Long getVirtualCoin() {
        return virtualCoin;
    }

    public void setVirtualCoin(Long virtualCoin) {
        this.virtualCoin = virtualCoin;
    }

    @JsonProperty("imgUrl")
    private String imgUrl = null;

    public OrderSkuListCusVo skuId(Long skuId) {
        this.skuId = skuId;
        return this;
    }

    /**
     * Get skuId
     *
     * @return skuId
     **/
    @ApiModelProperty(example = "123456", value = "")


    public Long getSkuId() {
        return skuId;
    }

    public void setSkuId(Long skuId) {
        this.skuId = skuId;
    }

    public OrderSkuListCusVo skuName(String skuName) {
        this.skuName = skuName;
        return this;
    }

    /**
     * Get skuName
     *
     * @return skuName
     **/
    @ApiModelProperty(example = "商品名称", value = "")


    public String getSkuName() {
        return skuName;
    }

    public void setSkuName(String skuName) {
        this.skuName = skuName;
    }

    public OrderSkuListCusVo quantity(Integer quantity) {
        this.quantity = quantity;
        return this;
    }

    /**
     * Get quantity
     *
     * @return quantity
     **/
    @ApiModelProperty(example = "10", value = "")


    public Integer getQuantity() {
        return quantity;
    }

    public void setQuantity(Integer quantity) {
        this.quantity = quantity;
    }

    public OrderSkuListCusVo unitPrice(BigDecimal unitPrice) {
        this.unitPrice = unitPrice;
        return this;
    }

    /**
     * Get unitPrice
     *
     * @return unitPrice
     **/
    @ApiModelProperty(example = "10.5", value = "")


    public BigDecimal getUnitPrice() {
        return unitPrice;
    }

    public void setUnitPrice(BigDecimal unitPrice) {
        this.unitPrice = unitPrice;
    }

    public OrderSkuListCusVo imgUrl(String imgUrl) {
        this.imgUrl = imgUrl;
        return this;
    }

    /**
     * 商品图片
     *
     * @return imgUrl
     **/
    @ApiModelProperty(example = "http://e.hiphotos.baidu.com/image/pic/item/48540923dd54564eaebe8b5dbede9c82d0584ffe.jpg", value = "商品图片")


    public String getImgUrl() {
        return imgUrl;
    }

    public void setImgUrl(String imgUrl) {
        this.imgUrl = imgUrl;
    }


    @Override
    public boolean equals(Object o) {
        if (this == o) {
            return true;
        }
        if (o == null || getClass() != o.getClass()) {
            return false;
        }
        OrderSkuListCusVo orderSkuListCusVo = (OrderSkuListCusVo) o;
        return Objects.equals(this.skuId, orderSkuListCusVo.skuId) &&
                Objects.equals(this.skuName, orderSkuListCusVo.skuName) &&
                Objects.equals(this.quantity, orderSkuListCusVo.quantity) &&
                Objects.equals(this.unitPrice, orderSkuListCusVo.unitPrice) &&
                Objects.equals(this.imgUrl, orderSkuListCusVo.imgUrl);
    }

    @Override
    public int hashCode() {
        return Objects.hash(skuId, skuName, quantity, unitPrice, imgUrl);
    }

    @Override
    public String toString() {
        StringBuilder sb = new StringBuilder();
        sb.append("class OrderSkuListCusVo {\n");

        sb.append("    skuId: ").append(toIndentedString(skuId)).append("\n");
        sb.append("    skuName: ").append(toIndentedString(skuName)).append("\n");
        sb.append("    quantity: ").append(toIndentedString(quantity)).append("\n");
        sb.append("    unitPrice: ").append(toIndentedString(unitPrice)).append("\n");
        sb.append("    imgUrl: ").append(toIndentedString(imgUrl)).append("\n");
        sb.append("}");
        return sb.toString();
    }

    /**
     * Convert the given object to string with each line indented by 4 spaces
     * (except the first line).
     */
    private String toIndentedString(Object o) {
        if (o == null) {
            return "null";
        }
        return o.toString().replace("\n", "\n    ");
    }

    public Long getSpuId() {
        return spuId;
    }

    public void setSpuId(Long spuId) {
        this.spuId = spuId;
    }
}

